package com.jade.zsy.base.entity;

import com.jade.bss.db.IdEntity;
import lombok.Data;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;


/**
 * 条码规则
 * User: jinya
 * Date: 2017/6/32130656785
 * Time: 14:08
 * TEL :17701640710   MAIL:2009_jinya@163.com
 * To change this template use File | Settings | File Templates.
 */
@Data
@Entity
@Table(name = "ZSY_BASE_BARCODE_RULE")
public class BarcodeRule extends IdEntity {
    public static final int RULE_EMPTY=0;//空编码
    public static final  int RULE_FIXED=1;//固定编码
    public static final  int RULE_SUPPLIER=2;//供应商编码
    public static final  int RULE_SKU=3;//货号或者商品编码
    public static final  int RULE_TYPE=4;//商品属性或者特性
    public static  final int RULE_RANDOM=5;//商品属性或者特性

    public static  final  int TYPE_EMPTY=0;//没有
    public static  final  int TYPE_YEAR_1=1;//年（17）
    public static  final  int TYPE_YEARMONTH_1=2;//年月（1706）
    public static  final  int TYPE_YEARMONTHDAY_1=3;//年月日（170610）
    public static  final  int TYPE_YEAR_2=4;//年（17）
    public static  final  int TYPE_YEARMONTH_2=5;//年月（1706）
    public static  final  int TYPE_YEARMONTHDAY_2=6;//年月日（170610）

    @Column(name = "codeHelp", nullable = false, updatable = true)
    private String codeHelp;//助记码
    @Column(name = "title", nullable = false, updatable = true)
    private String title;//标题
    @Column(name = "firstLevel", nullable = false, updatable = true)
    private int firstLevel=RULE_EMPTY;//第一级别
    @Column(name = "firstType", nullable = false, updatable = true)
    private int firstType=TYPE_EMPTY;//第一级别类型
    @Column(name = "firstObject", nullable = false, updatable = true)
    private String firstObject;
    @Column(name = "secondLevel", nullable = false, updatable = true)
    private int secondLevel=RULE_EMPTY;//第二级别
    @Column(name = "secondType", nullable = false, updatable = true)
    private int secondType=TYPE_EMPTY;//第二级别类型
    @Column(name = "secondObject", nullable = false, updatable = true)
    private String secondObject;
    @Column(name = "thirdLevel", nullable = false, updatable = true)
    private int thirdLevel=RULE_EMPTY;//第三级别
    @Column(name = "thirdType", nullable = false, updatable = true)
    private int thirdType=TYPE_EMPTY;//第二级别类型
    @Column(name = "thirdObject", nullable = false, updatable = true)
    private String thirdObject;
    @Column(name = "sixLevle", nullable = false, updatable = true)
    private int sixLevle=RULE_EMPTY;
    @Column(name = "serialNoLength", nullable = false, updatable = true)
    private int serialNoLength;
}
